/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #A375FF;
    --primary-dark: #8c5fe6;
    --primary-light: #b894ff;
    --text-white: #ffffff;
    --text-light: #f8f9fa;
    --text-dark: #333333;
    --text-gray: #666666;
    --bg-light: #f5f6fa;
    --sidebar-bg: #2d3748;
    --card-bg: rgba(255, 255, 255, 0.95);
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --info-color: #17a2b8;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Microsoft YaHei', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: var(--text-dark);
    min-height: 100vh;
    line-height: 1.6;
}

/* 头部导航栏 */
.header {
    background: var(--primary-color);
    padding: 0;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    height: 60px;
}

.location {
    display: flex;
    align-items: center;
    color: var(--text-white);
    font-weight: 600;
    font-size: 14px;
}

.location-icon {
    margin-right: 8px;
    font-size: 16px;
}

.main-nav {
    display: flex;
    gap: 5px;
}

.nav-item {
    text-decoration: none;
    color: var(--text-white);
    font-weight: 500;
    padding: 15px 20px;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
    font-size: 14px;
    white-space: nowrap;
}

.nav-item:hover,
.nav-item.active {
    background: var(--primary-dark);
    border-bottom-color: var(--text-white);
}

.user-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.login-btn {
    background: rgba(255, 255, 255, 0.2);
    color: var(--text-white);
    padding: 8px 20px;
    border-radius: 20px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    font-size: 14px;
    border: none;
    cursor: pointer;
}

.login-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.user-icon {
    color: var(--text-white);
    font-size: 20px;
    text-decoration: none;
}

.back-btn {
    background: rgba(255, 255, 255, 0.2);
    color: var(--text-white);
    border: none;
    padding: 8px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    font-size: 14px;
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* 侧边栏 */
.sidebar {
    position: fixed;
    left: 0;
    top: 60px;
    width: 280px;
    height: calc(100vh - 60px);
    background: var(--sidebar-bg);
    color: var(--text-white);
    padding: 0;
    overflow-y: auto;
    transition: all 0.3s ease;
    z-index: 999;
}

.sidebar.collapsed {
    width: 60px;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid #4a5568;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sidebar-header h3 {
    color: var(--text-white);
    font-size: 16px;
    margin: 0;
}

.collapse-btn {
    background: none;
    border: none;
    color: var(--text-white);
    cursor: pointer;
    font-size: 14px;
    padding: 5px;
    transition: all 0.3s ease;
}

.collapse-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

.project-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.project-list li {
    border-bottom: 1px solid #4a5568;
}

.project-list a {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    color: var(--text-light);
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 14px;
}

.project-list a:hover,
.project-list a.active {
    background: var(--primary-color);
    color: var(--text-white);
}

.project-icon {
    margin-right: 12px;
    font-size: 16px;
    min-width: 20px;
    text-align: center;
}

.project-text {
    white-space: nowrap;
    overflow: hidden;
}

.sidebar.collapsed .project-text {
    display: none;
}

.latest-notice {
    padding: 20px;
    border-top: 1px solid #4a5568;
}

.latest-notice h4 {
    color: var(--text-white);
    margin-bottom: 15px;
    font-size: 14px;
}

.notice-content {
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 8px;
}

.notice-content p {
    margin-bottom: 8px;
    font-size: 12px;
    color: var(--text-light);
    line-height: 1.4;
}

/* 主内容区 */
.main-content {
    margin-left: 280px;
    padding: 30px;
    min-height: calc(100vh - 60px);
    transition: margin-left 0.3s ease;
}

.sidebar.collapsed ~ .main-content {
    margin-left: 60px;
}

/* 页面内容样式 */
.page-content {
    background: var(--card-bg);
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
}

/* 移动端菜单按钮 */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-white);
    font-size: 20px;
    cursor: pointer;
    padding: 10px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .mobile-menu-btn {
        display: block;
    }
    
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.mobile-open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
        padding: 15px;
    }
    
    .header-container {
        padding: 0 15px;
    }
    
    .main-nav {
        display: none;
    }
    
    .nav-item {
        padding: 10px 15px;
        font-size: 12px;
    }
    
    .page-content {
        padding: 20px;
    }
}